# Contributor: Eric Bélanger <eric@archlinux.org>

pkgname=popt
pkgver=1.18
pkgrel=1
pkgdesc="A commandline option parser"
arch=('x86_64')
url="https://github.com/rpm-software-management/popt"
license=('custom')
depends=('glibc')
options=('staticlibs')
#source=(http://rpm5.org/files/${pkgname}/${pkgname}-${pkgver}.tar.gz)
source=(http://ftp.rpm.org/popt/releases/popt-1.x/popt-${pkgver}.tar.gz)
sha1sums=('0bf05488e151228fce9c0c9601162a9f432f69d9')

build() {
  cd "${pkgname}-${pkgver}"
  ./configure --prefix=/usr
  make
}

package() {
  cd "${pkgname}-${pkgver}"
  make DESTDIR="${pkgdir}" install
  install -Dm644 COPYING "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
}
